﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace SimCMS.Common
{
     public static  class CommonHelper
    {
         /// <summary>
         /// 分页的每页的条数
         /// </summary>
         public static int PageSize = 20;

         /// <summary>
         /// 如果是true，禁用，
         /// </summary>
         /// <param name="IsTrue"></param>
         /// <returns></returns>
         public static string IsStatus(bool IsTrue)
         {
             if(IsTrue)
                 return "禁用";
             else
                 return "开启";
         }

         public static int GetParentId(int Level,string LevelTree)
         {
            return int.Parse( LevelTree.Substring(Level * 3, 3));
         }
    }
}
